package com.jkoss.dao.oa;

import com.jkoss.pojo.oa.Empattendance;
import com.jkoss.pojo.oa.EmpattendanceExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.ResultType;
import org.apache.ibatis.annotations.Select;

public interface EmpattendanceMapper {
	
	@Select("SELECT kqid FROM t_empattendance  where empid=#{empid}  and date_format(kqdate1, '%Y-%m-%d') =#{day}")
	@ResultType(java.lang.Integer.class)
	Integer findIDByDate_EmpID(@Param("empid") int empid,@Param("day") String day);
	
	@Select("SELECT * FROM t_empattendance  where empid=#{empid} and date_format(kqdate1, '%Y-%m')=#{mth} order by kqdate1")
	List<Empattendance> findAllByEmpid_Mth(@Param("empid") int empid,@Param("mth") String mth); 
	
    int countByExample(EmpattendanceExample example);

    int deleteByExample(EmpattendanceExample example);

    int deleteByPrimaryKey(Integer kqid);

    int insert(Empattendance record);

    int insertSelective(Empattendance record);

    List<Empattendance> selectByExample(EmpattendanceExample example);

    Empattendance selectByPrimaryKey(Integer kqid);

    int updateByExampleSelective(@Param("record") Empattendance record, @Param("example") EmpattendanceExample example);

    int updateByExample(@Param("record") Empattendance record, @Param("example") EmpattendanceExample example);

    int updateByPrimaryKeySelective(Empattendance record);

    int updateByPrimaryKey(Empattendance record);
}